//
//  TuijianCell_c.m
//  网易新闻
//
//  Created by dllo on 15/10/7.
//  Copyright (c) 2015年 Lx. All rights reserved.
//
#import "TuijianCell_c.h"
@interface TuijianCell_c()
@property(nonatomic, retain)UIImageView *img_b;
@property(nonatomic, retain)UIImageView *img_c;
@end
@implementation TuijianCell_c
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.img_b = [[UIImageView alloc]init];
        self.img_b.backgroundColor = [UIColor lightGrayColor];
        [self.background addSubview:self.img_b];
        [self.img_b release];
        
        self.img_c = [[UIImageView alloc]init];
        self.img_c.backgroundColor = [UIColor lightGrayColor];
        [self.background addSubview:self.img_c];
        [self.img_c release];
    }
    return self;
}

- (void)layoutSubviews{
    [super layoutSubviews];
    self.img.frame = CGRectMake(0, 0, 217, 195);
    self.img_b.frame = CGRectMake(220, 0, 130, 96);
    self.img_c.frame = CGRectMake(220, 99, 130, 96);
}

- (void)setMod:(TuijianModel *)mod{
    if (_mod != mod) {
        [_mod release];
        _mod = [mod retain];
    }
    [self setOtherMod:mod];
    
    [self.img_b sd_setImageWithURL:[[mod.imgnewextra objectAtIndex:0]objectForKey:@"imgsrc"] placeholderImage:nil];
    [self.img_c sd_setImageWithURL:[[mod.imgnewextra objectAtIndex:1]objectForKey:@"imgsrc"] placeholderImage:nil];
}

- (void)dealloc{
    [_img_b release];
    [_img_c release];
    [super dealloc];
}

@end

